package user

import (
	"context"
)

type CommonUserBindRepoIface interface {
	//获取详情
	GetInfo(ctx context.Context, condition map[string]interface{}) (*CommonUserBind, error)
	//获取列表数据
	GetList(ctx context.Context, condition map[string]interface{}, page, pagesize int, orderBy string) (int64, []*CommonUserBind, error)
	//更新数据
	Update(ctx context.Context, data, condition map[string]interface{}) (bool, error)
	//插入数据
	Insert(ctx context.Context, commonUserBind *CommonUserBind) (bool, error)
	InsertFailRecord(ctx context.Context, commonUserBindFailRecord *CommonUserBindFailRecord) (bool, error)
	//逻辑删除数据
	Delete(ctx context.Context, condition map[string]interface{}) (bool, error)
	GetDistinctMpOpenidsByCommonUserId(ctx context.Context, commonUserId string) ([]string, error)
	GetLastBindByMobile(ctx context.Context, mobile string, excludeCommonUserId string) (commonUserBind *CommonUserBind, err error)
	BindMpOpenids(ctx context.Context, commonUserDataUid string, tenantUserUid string, mpOpenids []string) error
}
